package remoto;

import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;

import facade.FachadaServicos;

public class Servidor {

	public Servidor() {
		iniciar();
	}

	public void iniciar() {
		try {
			
			Registry registry = LocateRegistry.createRegistry(8888);
			registry.rebind("servicos", new FachadaServicos());
			
			System.out.println("Servidor Iniciado!");
		} catch (Exception e) {
			e.printStackTrace();
		}
	}

	public static void main(String[] args) {
		new Servidor();
	}

}
